-
Notifications
You must be signed in to change notification settings - Fork 608
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
change src for invoice logo image #1326
Conversation
Autotagging @bigcommerce/storefront-team @davidchin |
@@ -6,7 +6,7 @@ | |||
<div class="Invoice"> | |||
<h1> | |||
{{#if settings.store_logo.image}} | |||
<img class="header-logo-image lazyload" data-sizes="auto" src="{{cdn 'img/loading.svg'}}" data-src="{{getImage settings.store_logo.image 'logo_size'}}" alt="{{settings.store_logo.title}}" title="{{settings.store_logo.title}}"> | |||
<img class="header-logo-image lazyload" data-sizes="auto" src="{{getImage settings.store_logo.image}}" data-src="{{getImage settings.store_logo.image 'logo_size'}}" alt="{{settings.store_logo.title}}" title="{{settings.store_logo.title}}"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So this is a lazy load image which will load the loading image first & then replace it will original image. Do we see anything in the console as to why the image is not loading ? Or else we completely remove lazy loading. See https://github.com/bigcommerce/cornerstone/blob/81d24b58633365ea1974e9d3e633111d66cc6d57/templates/components/common/store-logo.html
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I looked into that and find out that this issue happens because of the printing (the image is not ready by the time the printing windows opened.
I delete the lazy load and used the same method as referenced, however, the code in the reference use lazy load as well so I should modify it according to the requirements.
💚 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
Moved #1326 changelog entry to Draft.
What?
Logo img in the invoice is missing. This change will add logo img to the invoice
Screenshots
Before
After
Original logo size
Optimized
Specified Dimensions